Functions
Event and Exception

Includes APIs of events and exceptions. More...

Functions

def MV_CC_RegisterExceptionCallBack (self, ExceptionCallBackFun, pUser)
 Registers an exception callback. More...
 
def MV_CC_RegisterAllEventCallBack (self, EventCallBackFun, pUser)
 Registers a callback for all events. More...
 
def MV_CC_RegisterEventCallBackEx (self, pEventName, EventCallBackFun, pUser)
 Registers a callback for single event. More...
 
def MV_CC_EventNotificationOn (self, strEventName)
 Enables specified event of device. More...
 
def MV_CC_EventNotificationOff (self, strEventName)
 Disables specified event of device. More...
 

Detailed Description

Includes APIs of events and exceptions.

Function Documentation

◆ MV_CC_RegisterExceptionCallBack()

def MvCameraControl_class.MV_CC_RegisterExceptionCallBack (   self,
  ExceptionCallBackFun,
  pUser 
)

Registers an exception callback.

Parameters
handle[IN] It refers to the device handle.
cbException[IN] It refers to the pointer to the exception callback function.
pUser[IN] It refers to the user-defined variable.
Returns
Returns MV_OK for success, and returns corresponding Error Code for failure.
Remarks
  • Call this API after MV_CC_OpenDevice().
  • When the device is exceptionally disconnected, you can get the exception message from callback function. For disconnected GigE vision device, call MV_CC_CloseDevice() to turn off the device, and then call MV_CC_OpenDevice() to turn on the device again.

◆ MV_CC_RegisterAllEventCallBack()

def MvCameraControl_class.MV_CC_RegisterAllEventCallBack (   self,
  EventCallBackFun,
  pUser 
)

Registers a callback for all events.

Parameters
handle[IN] It refers to the device handle.
cbEvent[IN] It refers to the pointer to event callback function.
pUser[IN] It refers to the user-defined variable.
Returns
Returns MV_OK for success, and returns corresponding Error Code for failure.
Remarks
  • Call this API after MV_CC_OpenDevice().
  • Call this API to set the event callback function to get event information including acquisition and exposure.

◆ MV_CC_RegisterEventCallBackEx()

def MvCameraControl_class.MV_CC_RegisterEventCallBackEx (   self,
  pEventName,
  EventCallBackFun,
  pUser 
)

Registers a callback for single event.

Parameters
handle[IN] It refers to the device handle.
strEventName[IN] It refers to the event name.
cbEvent[IN] It refers to the pointer to event callback function.
pUser[IN] It refers to the user-defined variable.
Returns
Returns MV_OK for success, and returns corresponding Error Code for failure.
Remarks
  • Call this API after MV_CC_OpenDevice().
  • Call this API to set the event callback function to get event information including acquisition and exposure.

◆ MV_CC_EventNotificationOn()

def MvCameraControl_class.MV_CC_EventNotificationOn (   self,
  strEventName 
)

Enables specified event of device.

Parameters
handle[IN] It refers to the device handle.
strEventName[IN] It refers to the event name.
Returns
Returns MV_OK for success, and returns corresponding Error Code for failure.

◆ MV_CC_EventNotificationOff()

def MvCameraControl_class.MV_CC_EventNotificationOff (   self,
  strEventName 
)

Disables specified event of device.

Parameters
handle[IN] It refers to the device handle.
strEventName[IN] It refers to the event name.
Returns
Returns MV_OK for success, and returns corresponding Error Code for failure.